#ifndef RAY_HH_
# define RAY_HH_

# include <math/vector.hh>
# include "../display/object.hh"
# include <math/plane.hh>

class Ray
{
public:
  Ray (Vector3f point);
  ~Ray ();

  void set_line (Vector3f& point);
  bool intersect (const Vector3f& pos, const BoundingSphere* s);
  bool intersect (const Vector3f& pos, const BoundingBox* s);

  Vector3f* intersect (Plane* p);

  Vector3f& p_get () { return p_; }
  Vector3f& u_get () { return u_; }
  Vector3f& p2_get () { return p2_; }

protected:
  Vector3f u_;
  Vector3f p_;
  Vector3f p2_;
};

#endif /// RAY_HH_
